package com.wangyadong.hobby.thread.javalistion;

public class Main {
    public static void main(String[] args) {
        EventSource source = new EventSource();
        try {
            source.addListener((e) -> System.out.println("Click event performed!"));
            source.actionPerformed();
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
    }
}